<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>星途影视</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <meta name="keyword" content="">
    <meta name="description" content="">
    <link rel="stylesheet" href="css/normalize.css">
    <link rel="stylesheet" href="css/style.css">
    <link rel="stylesheet" href="css/online-server.css">
</head>
<body>
    <!--HEADER-->
    <div id="header">
        <p class="header-content">星途影视</p>
        <span class="back">&lt;</span>
    </div>
    <div class="mt1_5"></div>
    <div class="chat-window">
        <div class="our-send">
            <div class="send-img" style="background: url('img/ad01.png') center center/cover no-repeat"></div>
            <div class="send-text">
                您好！尊敬的用户有什么可以帮助您的？
            </div>
        </div>
    </div>

    <!--消息发送栏-->
    <div class="send-box">
        <div class="text-box">
            <textarea name="" id="user-send" placeholder="请输入要发送的信息"></textarea>
        </div>
        <div class="send-btn">
            <input type="button" value="发送">
        </div>
    </div>
<script src="js/fontSize.js"></script>
<script src="https://cdn.bootcss.com/jquery/3.3.1/jquery.min.js"></script>
<script src="js/main.js"></script>
    <script>
        $(".send-btn input").on("click",function () {
            var userSend = $("#user-send").val();
            console.log(userSend);
            $("#user-send").val("");
            if(userSend == undefined){
                alert("请输入您需要咨询的问题");
            }else{
                var html = `
                     <div class="user-send">
                        <div class="send-img"></div>
                        <div class="send-text">
                            ${userSend}
                        </div>
                    </div>
                `
                $(".chat-window").append(html);
                setTimeout(function () {
                    var html = `
                         <div class="our-send">
                            <div class="send-img" style="background: url('img/ad01.png') center center/cover no-repeat"></div>
                            <div class="send-text">
                                您好！在线客服暂时忙！建议拨打热线：13333333333
                            </div>
                        </div>
                    `;
                    $(".chat-window").append(html);
                },3000)
            }
        })


    </script>
</body>
</html>